package com.woniuxy.stage3demo.controller.controllerhpd;


import com.woniuxy.stage3demo.bean.hpd.ProductLogBean;
import com.woniuxy.stage3demo.service.servicehpd.IProductLogService;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;
import java.util.List;

@RequestMapping("/productLog")
@RestController
public class ProductLogController {
    @Resource
    private IProductLogService productLogServiceImpl;

    //根据产品Id查询日志
    @GetMapping(value = "/page",produces = {"application/json;charset=utf-8"})
    public List<ProductLogBean> findByProId(Long id){
        List<ProductLogBean> productLogBeans = productLogServiceImpl.findByProductId(id);
        return productLogBeans;
    }

}
